/*
 * Created by Jaren at 2021/11/29 7:46
 */

import 'package:inmotion_protocol/common/product_model.dart';
import 'package:inmotion_protocol/common/product_version.dart';
import 'package:inmotion_protocol/common/vehicle_info.dart';

abstract class MsgFactory<T> {
  ProductModel model = ProductModel.unknown;
  VersionWrapper version = VersionWrapper();

  void init(ProductProperty productProperty);
}

abstract class SimpleBMSFeatureMsgFactoryTrait<T> {
  T genRequestBMSCellsVoltageInfoMsg(int target);
}

abstract class FullBMSFeatureMsgFactoryTrait<T> extends SimpleBMSFeatureMsgFactoryTrait<T> {
  T genRequestBMSRealTimeInfoMsg(int target);

  T genRequestBMSFixedInfoMsg(int target);

  T genRequestBMSDateMsg(int target);
}

abstract class BMSLogMsgFactoryTrait<T> {
  T genRequestBMSLogCountMsg(int target);

  T genRequestBMSLogMsg(int target, int index);
}
